package com.sykj.controller;

import com.sykj.bean.card.BisNurseBagDto;
import com.sykj.mapper.GameLoadMapper;
import com.sykj.service.CardUserHitService;
import com.sykj.util.reponse.CommonEnum;
import com.sykj.util.reponse.ResultBody;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @program: BeautyClub
 * @description: 用户中奖纪录接口
 * @author: qiaoli
 * @create: 2020-08-08 15:49
 */
@RestController
@RequestMapping("/hit")
public class CardUserHitController {
    @Autowired
    GameLoadMapper gameLoadMapper;

    @GetMapping("/queryhit/{gameid}/{customUserId}")
    public ResultBody  queryUserByid(@PathVariable("customUserId")String customUserId ,
                                     @PathVariable("gameid")String gameid){
        List<BisNurseBagDto> bisNurseBagDtos = gameLoadMapper.queryByid(gameid, customUserId);
        return new ResultBody(CommonEnum.SUCCESS,bisNurseBagDtos);
    }
}
